﻿using System;
using System.Xml.Linq;

namespace xycn.ILogHelper
{
    /// <summary>
    /// 日志辅助类，基于 log4实现 
    /// mrking 2021-03-14
    /// </summary>
    public interface ILogHelper
    {
        /// <summary>
        /// 普通信息
        /// </summary>
        /// <param name="msg"></param>
        void Info(string msg);

        /// <summary>
        /// 普通信息
        /// </summary>
        /// <param name="msg"></param>
        void Info(string msg, bool is_debug);

        /// <summary>
        /// 
        /// </summary>
        /// <param name="msg"></param>
        /// <param name="repmsg"></param>
        /// <param name="resmsg"></param>
        void Info(string msg, object repmsg = null, object resmsg = null, bool is_debug = true);

        /// <summary>
        /// 普通信息
        /// </summary>
        /// <param name="msg"></param>
        void Warn(string msg, bool is_debug = true);

        /// <summary>
        /// 
        /// </summary>
        /// <param name="msg"></param>
        /// <param name="repmsg"></param>
        /// <param name="resmsg"></param>
        void Warn(string msg, object repmsg = null, object resmsg = null, bool is_debug = true);

        /// <summary>
        /// 普通信息
        /// </summary>
        /// <param name="msg"></param>
        void Error(string msg, bool is_debug = true);

        /// <summary>
        /// 
        /// </summary>
        /// <param name="msg"></param>
        /// <param name="repmsg"></param>
        /// <param name="resmsg"></param>
        void Error(string msg, object repmsg = null, object resmsg = null, bool is_debug = true);

        /// <summary>
        /// 错误信息
        /// </summary>
        /// <param name="ex"></param>
        /// <param name="remark"></param>
        /// <param name="reqdata"></param>
        void Error(Exception ex, string remark, object reqdata = null, bool is_debug = true);

        /// <summary>
        /// 错误信息
        /// </summary>
        /// <param name="ex"></param>
        /// <param name="remark"></param>
        /// <param name="reqdata"></param>
        void Exception(Exception ex, string remark, object reqdata = null, object resdata = null, bool is_debug = true);
    }
}
